{% extends "base.html" %}

{% block content %}
<div class="panel" v-pre>
  <div class="panel-body">
    <form action="{{shard.url}}/graph">
      <dl class="dl-horizontal">
        <dt>Query</dt>
        <dd><pre>{{expr}}</pre></dd>
        <dt>Range</dt>
        <dd>{{range_input}}</dd>
        <dt>End</dt>
        <dd>{{end_input}}</dd>
        <dt>Step</dt>
        <dd>{{step_input}}</dd>
    </form>
    <ul class="list-inline">
    {% for shard in shard_list|dictsort:'name' %}
      <li>
        <form action="{{shard.url}}/graph">
            <input name="g0.expr" type="hidden" value="{{expr}}" />
            <input name="g0.range_input" type="hidden" value="{{range_input}}" />
            <input name="g0.end_input" type="hidden" value="{{end_input}}" />
            <input name="g0.step_input" type="hidden" value="{{step_input}}" />
            <input name="g0.tab" type="hidden" value="{{tab}}" />
            <input name="g0.stacked" type="hidden" value="{{stacked}}" />
            <button class="btn btn-info">View on {{shard.name}}</button>
        </form>
      </li>
    {% endfor %}
    </ul>
  </div>
</div>
{% endblock %}
